/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package oplm;

import java.text.ParseException;
import java.text.SimpleDateFormat;
import javax.swing.JFormattedTextField;
import javax.swing.text.MaskFormatter;

/**
 *
 * @author hh
 */
public class CalenderTextField extends JFormattedTextField {

    public CalenderTextField() {
         super(new SimpleDateFormat("yyyy年MM月dd日 HH:ss"));
         
           MaskFormatter mf = null;
        try{
            mf = new MaskFormatter("####年##月##日 ##:##");
            mf.setPlaceholderCharacter('_');
        }catch(ParseException pe){
        }
        setFormatter(mf);
    }
    
    
}
